Ext.define('PAN.store.index.MenuStore',{
	extend:'Ext.data.TreeStore',
	root:{
		text: '系統',
        id: '0',
        tsn:0,
        expanded: true
	},
	fields:[
		'id','text','src','sn','lastsn','srt'
	],
	listeners:{
		beforeload:{
			 element:this,
			 fn:function(store,operation){
			 	store.getProxy().extraParams['sn'] = operation.node.get('sn');
			 }
		}
	},
	proxy:{
		type:'ajax',
		url:'/fsPro/home_backend.jsp?action=getMenuData',
		reader: {
            type: 'json',
            root: 'nodes'
        }
	}
})